function initMy(){
    	var chart = new Highcharts.Chart({
			chart : {
				renderTo : 'container',
				defaultSeriesType : 'column'

			},
			title : {
				text : '进出港中转旅客行李波'
			},

			plotOptions : {
				column : {
					stacking : 'normal'
				},
				series : {
					dataLabels : {
						enabled : true,
						formatter: function() {
					
					if(!isNaN(this.y )){
						
					}else{
					   //alert("不是数字");
					   this.series.options.dataLabels.y=0;
					   this.y=0;
						return "";
					}
											
						
						this.series.options.dataLabels.y =
                            this.y >= 0 ? -6 : 12;
						if(this.y<0){
							return 0-this.y ;
							}
						return	this.y;
                    }
					}
				}
			},
			xAxis : {
				categories :arrayAxis,
				title : {
					text : '时间(小时)'
				}
			},

			yAxis : {
				labels : {
					formatter : function() {
				if(!isNaN(this.value )){
					
				}else{
				   //alert("不是数字");
				  
					return 0;
				}
						if (this.value > 0) {
							//alert(this.value);
							return (this.value);
						}else{
							return 0 - this.value;
						}
					}
				},
				title : {
					text : '数目'
				}
			},
			tooltip : {
				formatter : function() {

					if (this.y > 0) {
						return '<b>' + this.y + '</b>';
					}
					//alert(this.y);
					if(!isNaN(this.y ) ){
						
					}else{
						return '<b>' + 0  + '</b>';
					}
					return '<b>' + (0 - this.y) + '</b>';

				}
			}
			,

			series :
			[{name:'旅客出港国内转国内',data:arrayBar1,stack:0},
       {name:'旅客出港国内转国际',data:arrayBar2,stack:0},
       {name:'旅客出港国际转国内',data:arrayBar3,stack:0},
       {name:'旅客出港国际转国际',data:arrayBar4,stack:0},
       {name:'旅客进港国内转国内',data:arrayBar5,stack:0},
       {name:'旅客进港国内转国际',data:arrayBar6,stack:0},
       {name:'旅客进港国际转国内',data:arrayBar7,stack:0},
       {name:'旅客进港国际转国际',data:arrayBar8,stack:0},
       {name:'行李出港国内转国内',data:arrayBar9,stack:1},
       {name:'行李出港国内转国际',data:arrayBar10,stack:1},
       {name:'行李出港国际转国内',data:arrayBar11,stack:1},
       {name:'行李出港国际转国际',data:arrayBar12,stack:1},
       {name:'行李进港国内转国内',data:arrayBar13,stack:1},
       {name:'行李进港国内转国际',data:arrayBar14,stack:1},
       {name:'行李进港国际转国内',data:arrayBar15,stack:1},
       {name:'行李进港国际转国际',data:arrayBar16,stack:1}
					]

		});
    	chart.redraw();
}



function initArray(){
	if($("#table")!=null){
		//alert("111");
		var d1=	$("#table").getCol("out_hh",false);
		var d2=	$("#table").getCol("out_hi",false);
		var d3=	$("#table").getCol("out_ih",false);
		var d4=	$("#table").getCol("out_ii",false);
		var d5=	$("#table").getCol("in_hh",false);
		var d6=	$("#table").getCol("in_hi",false);
		var d7=	$("#table").getCol("in_ih",false);
		var d8=	$("#table").getCol("in_ii",false);
		var d9=	$("#table").getCol("out_hh0",false);
		var d10=	$("#table").getCol("out_hi0",false);
		var d11=	$("#table").getCol("out_ih0",false);
		var d12=	$("#table").getCol("out_ii0",false);
		var d13=	$("#table").getCol("in_hh0",false);
		var d14=	$("#table").getCol("in_hi0",false);
		var d15=	$("#table").getCol("in_ih0",false);
		var d16=	$("#table").getCol("in_ii0",false);
 d1.shift();
 d2.shift();
 d3.shift();
 d4.shift();
 d5.shift();
 d6.shift();
 d7.shift();
 d8.shift();
 d9.shift();
d10.shift();
d11.shift();
d12.shift();
d13.shift();
d14.shift();
d15.shift();
d16.shift();
 var chartd1=[];
 var chartd2=[];
 var chartd3=[];
 var chartd4=[];
 var chartd5=[];
 var chartd6=[];
 var chartd7=[];
 var chartd8=[];
 var chartd9=[];
var chartd10=[];
var chartd11=[];
var chartd12=[];
var chartd13=[];
var chartd14=[];
var chartd15=[];
var chartd16=[];
		for(var i=0;i<24;i++){
 chartd1.push(parseInt(isNaN(d1[i])?0:d1[i]));
 chartd2.push(parseInt(isNaN(d2[i])?0:d2[i])); 
 chartd3.push(parseInt(isNaN(d3[i])?0:d3[i]));
 chartd4.push(parseInt(isNaN(d4[i])?0:d4[i]));
 chartd5.push(0-parseInt(isNaN(d5[i])?0:d5[i]));
 chartd6.push(0-parseInt(isNaN(d6[i])?0:d6[i]));
 chartd7.push(0-parseInt(isNaN(d7[i])?0:d7[i]));
 chartd8.push(0-parseInt(isNaN(d8[i])?0:d8[i]));
 chartd9.push(parseInt(isNaN(d9[i])?0:d9[i]));
chartd10.push(parseInt(isNaN(d10[i])?0:d10[i]));
chartd11.push(parseInt(isNaN(d11[i])?0:d11[i]));
chartd12.push(parseInt(isNaN(d12[i])?0:d12[i]));
chartd13.push(0-parseInt(isNaN(d13[i])?0:d13[i]));
chartd14.push(0-parseInt(isNaN(d14[i])?0:d14[i]));
chartd15.push(0-parseInt(isNaN(d15[i])?0:d15[i]));
chartd16.push(0-parseInt(isNaN(d16[i])?0:d16[i]));
			}
		
		   arrayBar1 =  chartd1;
 arrayBar2 =  chartd2;
 arrayBar3 =  chartd3;
 arrayBar4 =  chartd4;
 arrayBar5 =  chartd5;
 arrayBar6 =  chartd6;
 arrayBar7 =  chartd7;
 arrayBar8 =  chartd8;
 arrayBar9 =  chartd9;
arrayBar10 = chartd10;
arrayBar11 = chartd11;
arrayBar12 = chartd12;
arrayBar13 = chartd13;
arrayBar14 = chartd14;
arrayBar15 = chartd15;
arrayBar16 = chartd16;
		  
  
	}else{
		
	}
	
	
}


function printArray(){
	alert("出港:"+arrayInPortPlanBar+"\n"+"进港:"+arrayOutPortPlanBar+"\n"+"实际出港:"+arrayInPortActualLine+"\n"+"实际进港:"+arrayOutPortActualLine+"\n");
}

